<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<link rel="stylesheet" type="text/css" href="style/admin.css" />
<link rel="stylesheet" type="text/css" href="style/global.css" />
<script language="javascript" type="text/javascript"
	src="js/My97DatePicker/WdatePicker.js"></script>
<title>决策管理</title>
</head>
<style>
button {
	-moz-transition: -moz-box-shadow 0.2s linear 0s;
	background: -moz-linear-gradient(center top, #FFFFFF, #DDDDDD) repeat
		scroll 0 0 transparent;
	border: 1px solid #999999;
	border-radius: 5px 5px 5px 5px;
	box-shadow: 0 1px 0 rgba(255, 255, 255, 0.7), 0 -1px 0
		rgba(0, 0, 0, 0.09);
	color: #333333;
	cursor: pointer;
	display: inline-block;
	letter-spacing: 2px;
	line-height: 1;
	margin-left: 15px;
	overflow: visible;
	padding: 6px 8px;
	text-align: center;
	text-shadow: 0 1px 1px #FFFFFF;
	width: auto;
}
</style>
<body>
<div id="wrap">
<div class="m_head">
<div class="m_positin">工作量统计</div>
</div>
<div class="m_search">
	时间范围 <input class="Wdate" value='<?php echo $begtime?>' type="text" id='begtime' onClick="WdatePicker()"> 
	> <input class="Wdate" value='<?php echo $endtime?>' type="text" id='endtime' onClick="WdatePicker()"> 
	用户名：<input type="text" id='name' class='qi_text' value="<?php echo $name?>"/>
	<input class="btn_search" id='select' name="" type="button" value="" />
</div>
<div class="m_content">
<table class="qi_table" width="0" border="0" cellpadding="0"
	cellspacing="1">
	<tr>
		<th width="10%">用户姓名</th>
		<th width="10%">工号</th>
		<th width="10%">电话个数</th>
		<th width="25%">电话总时长</th>
		<th width="15%">短信条数</th>
		<th width="15%">问卷份数</th>
		<th width="10%">回访人数</th>
		<th width="5%">操作</th>
	</tr>
<?php 
	if(is_array($stats) && count($stats)>0){
		foreach ($stats as $v){
?>
                <tr>
					<td><?php echo $v['UNAME']?></td>
					<td><?php echo $v['CODE']?></td>
					<td><?php echo $v['TNUM']?$v['TNUM']:0?></td>
					<td>
						<?php echo '共计：'.ATools::formatSecond($v['TOLTIME']);?>
					</td>
					<td><?php echo $v['SNUM']?$v['SNUM']:0?></td>
					<td><?php echo $v['QNUM']?$v['QNUM']:0?></td>
					<td><?php echo $v['VNUM']?$v['VNUM']:0?></td>
					<td></td>
				</tr>
<?php
	}
} else {
	?>
             <tr>
		<td style="text-align: center; color: green;" colspan='10'>没有您搜索的结果</td>
	</tr>
<?php }?>
	<tr><td colspan='10'>
		 <?php 
			 $url = '/index.php?c='.$_REQUEST['c'].'&a='.$_REQUEST['a'].'&p=_num_&bt='.$begtime.'&et='.$endtime;
			 echo JYTools::pager($url,$tolNum,$page,$pagesize);
		 ?>
	</td></tr>
</table>
</div>
</div>
</body>
</html>
<script src="/js/xheditor/jquery/jquery-1.4.4.min.js" type="text/javascript"></script>
<script src="/js/boot.js" type="text/javascript"></script>
<script src="/js/tip.js" type="text/javascript"></script>
<script type="text/javascript">
$('#select').click(function(){
	var bt = $('#begtime').val()
	var et = $('#endtime').val()
	var name = $('#name').val()
	var url = '/index.php?c=stats&a=work_stats&et='+et+'&bt='+bt+'&p=<?php echo $page?>&name='+name;
	location.href=url;
})
</script>